// stores/counter.js
import {
	defineStore
} from 'pinia';
import {
	reactive,
	ref,
	watch
} from "vue"

export const useGlobalStore = defineStore('global', () => {
	const city = reactive({
		name:"广州",
		id:0
	});
	const changeIndex = ref(0) ;
	const cityList = ref([]);
	const hotsList = ref([]);
	const cacheList = ref([]);
	watch(changeIndex.value,()=>{
		console.log(111);
	})
	return {
		city,
		cityList,
		hotsList,
		cacheList
	}
});